package me.zk.entity;

import org.springframework.data.annotation.CreatedDate;
import org.springframework.data.annotation.LastModifiedDate;

import javax.persistence.Column;
import javax.persistence.MappedSuperclass;
import java.util.Date;

/**
 * @Author: zhang kai
 * @Date: 2022/11/18
 * @Description:
 */
@MappedSuperclass
public class BaseEntity {

    @Column(name = "is_del")
    private Integer isDel;

    @CreatedDate
    @Column(name = "created_at", updatable = false)
    private Date createdAt;

    @LastModifiedDate
    @Column(name = "modified_at")
    private Date modifiedAt;
}
